package com.homedo.microservice.open.service.gateway.alert.gateway.bean.po;

import com.homedo.common.dao.bean.po.base.BasePo;

import javax.persistence.Column;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;

/**
 * 网关过滤器配置表--默认配置
 *
 * @author 作者 jgshun
 * @date 创建时间 2018年09月14日 14时56分00秒
 */
@Table(name = "d_zuul_filter_default")
public class ZuulFilterDefault extends BasePo {
    /**
     * 属性查询列表
     */
    public static final String FIELD_ID = "id";
    public static final String FIELD_APPLICATIONNAME = "applicationName";
    public static final String FIELD_FILTERID = "filterId";
    public static final String FIELD_FILTERNAME = "filterName";
    public static final String FIELD_REVISION = "revision";
    public static final String FIELD_STATUS = "status";
    public static final String FIELD_PROGRESS = "progress";
    public static final String FIELD_FILTERTYPE = "filterType";
    public static final String FIELD_DISABLEPROPERTYNAME = "disablePropertyName";
    public static final String FIELD_FILTERORDER = "filterOrder";
    public static final String FIELD_CREATETIME = "createTime";
    public static final String FIELD_UPDATETIME = "updateTime";
    public static final String FIELD_COMMENT = "comment";

    /**
     * 列名查询列表
     */
    public static final String COLUMN_ID = "id";
    public static final String COLUMN_APPLICATION_NAME = "application_name";
    public static final String COLUMN_FILTER_ID = "filter_id";
    public static final String COLUMN_FILTER_NAME = "filter_name";
    public static final String COLUMN_REVISION = "revision";
    public static final String COLUMN_STATUS = "status";
    public static final String COLUMN_PROGRESS = "progress";
    public static final String COLUMN_FILTER_TYPE = "filter_type";
    public static final String COLUMN_DISABLE_PROPERTY_NAME = "disable_property_name";
    public static final String COLUMN_FILTER_ORDER = "filter_order";
    public static final String COLUMN_CREATE_TIME = "create_time";
    public static final String COLUMN_UPDATE_TIME = "update_time";
    public static final String COLUMN_COMMENT = "comment";


    @Id

    @GeneratedValue(generator = "JDBC")

    @Column(name = "id")
    private Integer id;


    @Column(name = "application_name")
    private String applicationName;


    @Column(name = "filter_id")
    private String filterId;


    @Column(name = "filter_name")
    private String filterName;


    @Column(name = "revision")
    private Integer revision;


    @Column(name = "status")
    private Integer status;


    @Column(name = "progress")
    private Integer progress;


    @Column(name = "filter_type")
    private String filterType;


    @Column(name = "disable_property_name")
    private String disablePropertyName;


    @Column(name = "filter_order")
    private Integer filterOrder;


    @Column(name = "create_time")
    private Date createTime;


    @Column(name = "update_time")
    private Date updateTime;

    @Column(name = "comment")
    private String comment;

    /**
     * 获取 主键ID
     *
     * @return id - 主键ID
     */
    public Integer getId() {
        return id;
    }

    /**
     * 设置 主键ID
     *
     * @param id - 主键ID
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * 获取 应用名称
     *
     * @return applicationName - 应用名称
     */
    public String getApplicationName() {
        return applicationName;
    }

    /**
     * 设置 应用名称
     *
     * @param applicationName - 应用名称
     */
    public void setApplicationName(String applicationName) {
        this.applicationName = applicationName;
    }

    /**
     * 获取 过滤器id
     *
     * @return filterId - 过滤器id
     */
    public String getFilterId() {
        return filterId;
    }

    /**
     * 设置 过滤器id
     *
     * @param filterId - 过滤器id
     */
    public void setFilterId(String filterId) {
        this.filterId = filterId;
    }

    /**
     * 获取 名称
     *
     * @return filterName - 名称
     */
    public String getFilterName() {
        return filterName;
    }

    /**
     * 设置 名称
     *
     * @param filterName - 名称
     */
    public void setFilterName(String filterName) {
        this.filterName = filterName;
    }

    /**
     * 获取 版本
     *
     * @return revision - 版本
     */
    public Integer getRevision() {
        return revision;
    }

    /**
     * 设置 版本
     *
     * @param revision - 版本
     */
    public void setRevision(Integer revision) {
        this.revision = revision;
    }

    /**
     * 获取 是否可用
     *
     * @return status - 是否可用
     */
    public Integer getStatus() {
        return status;
    }

    /**
     * 设置 是否可用
     *
     * @param status - 是否可用
     */
    public void setStatus(Integer status) {
        this.status = status;
    }

    /**
     * 获取 当前所处进度
     *
     * @return progress - 当前所处进度
     */
    public Integer getProgress() {
        return progress;
    }

    /**
     * 设置 当前所处进度
     *
     * @param progress - 当前所处进度
     */
    public void setProgress(Integer progress) {
        this.progress = progress;
    }

    /**
     * 获取 filter类型
     *
     * @return filterType - filter类型
     */
    public String getFilterType() {
        return filterType;
    }

    /**
     * 设置 filter类型
     *
     * @param filterType - filter类型
     */
    public void setFilterType(String filterType) {
        this.filterType = filterType;
    }

    /**
     * 获取 禁用属性
     *
     * @return disablePropertyName - 禁用属性
     */
    public String getDisablePropertyName() {
        return disablePropertyName;
    }

    /**
     * 设置 禁用属性
     *
     * @param disablePropertyName - 禁用属性
     */
    public void setDisablePropertyName(String disablePropertyName) {
        this.disablePropertyName = disablePropertyName;
    }

    /**
     * 获取 顺序
     *
     * @return filterOrder - 顺序
     */
    public Integer getFilterOrder() {
        return filterOrder;
    }

    /**
     * 设置 顺序
     *
     * @param filterOrder - 顺序
     */
    public void setFilterOrder(Integer filterOrder) {
        this.filterOrder = filterOrder;
    }

    /**
     * 获取 创建时间
     *
     * @return createTime - 创建时间
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * 设置 创建时间
     *
     * @param createTime - 创建时间
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    /**
     * 获取 更新时间
     *
     * @return updateTime - 更新时间
     */
    public Date getUpdateTime() {
        return updateTime;
    }

    /**
     * 设置 更新时间
     *
     * @param updateTime - 更新时间
     */
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getComment() {
        return comment;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        ZuulFilterDefault that = (ZuulFilterDefault) o;

        if (id != null ? !id.equals(that.id) : that.id != null) return false;
        if (applicationName != null ? !applicationName.equals(that.applicationName) : that.applicationName != null)
            return false;
        if (filterId != null ? !filterId.equals(that.filterId) : that.filterId != null) return false;
        if (filterName != null ? !filterName.equals(that.filterName) : that.filterName != null) return false;
        if (revision != null ? !revision.equals(that.revision) : that.revision != null) return false;
        if (status != null ? !status.equals(that.status) : that.status != null) return false;
        if (progress != null ? !progress.equals(that.progress) : that.progress != null) return false;
        if (filterType != null ? !filterType.equals(that.filterType) : that.filterType != null) return false;
        if (disablePropertyName != null ? !disablePropertyName.equals(that.disablePropertyName) : that.disablePropertyName != null)
            return false;
        if (filterOrder != null ? !filterOrder.equals(that.filterOrder) : that.filterOrder != null) return false;
        if (createTime != null ? !createTime.equals(that.createTime) : that.createTime != null) return false;
        if (updateTime != null ? !updateTime.equals(that.updateTime) : that.updateTime != null) return false;
        return comment != null ? comment.equals(that.comment) : that.comment == null;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (applicationName != null ? applicationName.hashCode() : 0);
        result = 31 * result + (filterId != null ? filterId.hashCode() : 0);
        result = 31 * result + (filterName != null ? filterName.hashCode() : 0);
        result = 31 * result + (revision != null ? revision.hashCode() : 0);
        result = 31 * result + (status != null ? status.hashCode() : 0);
        result = 31 * result + (progress != null ? progress.hashCode() : 0);
        result = 31 * result + (filterType != null ? filterType.hashCode() : 0);
        result = 31 * result + (disablePropertyName != null ? disablePropertyName.hashCode() : 0);
        result = 31 * result + (filterOrder != null ? filterOrder.hashCode() : 0);
        result = 31 * result + (createTime != null ? createTime.hashCode() : 0);
        result = 31 * result + (updateTime != null ? updateTime.hashCode() : 0);
        result = 31 * result + (comment != null ? comment.hashCode() : 0);
        return result;
    }

    public void setComment(String comment) {
        this.comment = comment;

    }
}